package com.zd.service.impl;

import com.zd.mapper.DepartmentMapper;
import com.zd.model.Department;
import com.zd.service.IDepartmentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class DepartmentServiceImpl implements IDepartmentService {

    @Autowired
    private DepartmentMapper departmentMapper;

    @Override
    public List<Department> selectDepartmentInfo() {
        return departmentMapper.selectDepartmentInfo();
    }

    @Override
    public Department selectByPrimaryKey(int id) {

       return departmentMapper.selectByPrimaryKey(Long.valueOf(id));

    }
}
